package com.yj.rest;

import lombok.Data;

import java.util.Date;
import java.util.List;
import java.util.Objects;

@Data
public class EquipmentLocation {

    private String id;

    private String code;

    private String name;

    private String namePy;

    private String parentId;

    private String parentCode;

    private String parentName;

    private String orgId;

    private String orgName;

    private Integer level;

    private Integer levelCode;

    private String levelPath;

    private String fullPathCode;

    private String fullPathName;

    private Integer sort;

    private Integer deleteFlag;

    private String status;

    private String enterLatLon;

    private String csysType;

    private String latlon;

    private Integer range;

    private String desc;

    private String createUserId;

    private String createUserName;

    private Date createTime;

    private String updateUserId;

    private String updateUserName;

    private Date updateTime;

    private String height;

    // 业务字段
    private List<EquipmentLocation> children;

    //private List<Equipment> equipmentList;

    private Integer parentLevel;

    private String dataSources;

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        EquipmentLocation that = (EquipmentLocation) o;
        return id.equals(that.id);
    }

    @Override
    public int hashCode() {
        return Objects.hash(id);
    }
}